-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add upstreams and targets #99
Conversation
548dbce
to
d404300
Compare
Great stuff, thanks for the PR. I'll pull it down and review properly before merging. |
@CyExy I noticed that the checks were failing and looked at the TravisCi build. It seems that Kong is not being started on localhost. Any idea why that may be? |
I'll look into the Tarvis issue. |
Please could you rebase on the master, that fixes travis build |
This adds upstream and target capabilities to kongfig as requested in: mybuilder#69
d404300
to
ed9173f
Compare
@CyExy Let me know if there are any changes to be made. |
Sorry for the delay, and thanks for rebasing. I'm going to look through it first thing tomorrow morning. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea of breaking up the code a bit and adding the parsers dir.
There was a couple of issues, as I was looking into the issues I fixed them as well. patches
The first patch is fixing the issue with updating the target weight, and when you run and update the tests snapshots you can see the difference.
And the second patch resolves the issue with ensure: removed and setting the weight to 0. Currently when you set the ensure removed then it will try to remove the target every time you run the apply
. The second patch includes a fix for adding a target without attributes.
You have added the package-lock.json
I would think that it is best to move over to npm or add the package-lock.json
to .gitignore
because having two lock files in the project would just create confusion. I personally do prefer yarn over npm but not against changing it.
return t.target === target.target; | ||
}); | ||
|
||
return !!existing && diff(target.attributes, existing.attributes); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently changing the target weight doesn't trigger an update; return !!existing && diff(target.attributes, existing.attributes).length == 0
(notice the .length == 0
) fixes the issue
@dgarlitt I would like to send you a kongfig t-shirt, if interested please email me your postal address, size etc to sten [at] mybuilder.com add your github username as well so I know its you :) |
This adds upstream and target capabilities to kongconfig as requested
in: #69
This change closes #69